import fetch from 'utils/fetch';
// 现金借款分页
export function page(query) {
  return fetch({
    url: '/api/super/admin/marketProductInstallment',
    method: 'get',
    params: query
  });
}
// 文件上传
export function uploadFile(obj) {
    return fetch({
      url: '/api/super/admin/marketProduct/upload',
      method: 'post',
      data: obj
    });
  }
// 添加保存按钮
export function addCashLoan(obj) {
    return fetch({
      url: '/api/super/admin/marketProductInstallment',
      method: 'post',
      data: obj
    });
  }
// 删除 
export function delCashLoan(id) {
    return fetch({
        url: '/api/super/admin/marketProductInstallment/' + id,
        method: 'delete'
    })
}
// 修改
export function putCashLoan(obj) {
    return fetch({
      url: '/api/super/admin/marketProductInstallment',
      method: 'put',
      data: obj
    })
  }
// 上下架
export function editStatus(id, query) {
    return fetch({
      url: '/api/super/admin/marketProductInstallment/status/' + id,
      method: 'put',
      params: query
    })
  }